package com.example.hms.controller;

import com.example.hms.service.DashboardService;
import com.example.hms.ulit.Result;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RequestMapping("/dashboard")
@RestController
public class DashboardController {
    @Resource
    private DashboardService service;
    @RequestMapping(value = "/selectRoomNumber",method = RequestMethod.GET)
    public Result selectRoomNumber(){
        return service.selectRoomNumber();
    }
    @RequestMapping(value ="/selectLiveNumber",method = RequestMethod.GET)
    public Result selectLiveNumber(){
        return service.selectLiveNumber();
    }
    @RequestMapping(value ="/selectRevenue",method = RequestMethod.GET)
    public Result selectRevenue(String month){return service.selectRevenue(month);}
    @RequestMapping(value ="/selectRevenueByMonth",method = RequestMethod.GET)
    public Result selectRevenueByMonth(String month){return service.selectRevenueByMonth(month);}
}
